home *** CD-ROM | disk | FTP | other *** search
/ Amiga Format CD 7 / Amiga Format AFCD07 (Dec 1996, Issue 91).iso / serious / shareware / comms / non-internet / samba / docs / smbd.0 < prev    next >
Text File  |  1996-07-01  |  19KB  |  529 lines

  1.  
  2.  
  3.  
  4. SMBD(8)                        smbd                       SMBD(8)
  5.  
  6.  
  7. NNAAMMEE
  8.        smbd - provide SMB (aka LanManager) services to clients
  9.  
  10. SSYYNNOOPPSSIISS
  11.        ssmmbbdd  [ --DD ] [ --aa ] [ --dd _d_e_b_u_g_l_e_v_e_l ] [ --ll _l_o_g _f_i_l_e ] [ --pp
  12.        _p_o_r_t _n_u_m_b_e_r ] [ --OO _s_o_c_k_e_t _o_p_t_i_o_n_s  ]  [  --ss  _c_o_n_f_i_g_u_r_a_t_i_o_n
  13.        _f_i_l_e ]
  14.  
  15. DDEESSCCRRIIPPTTIIOONN
  16.        This program is part of the Samba suite.
  17.  
  18.        ssmmbbdd  is  a server that can provide most SMB services. The
  19.        server provides filespace and printer services to  clients
  20.        using  the  SMB protocol. This is compatible with the Lan-
  21.        Manager protocol, and can service LanManager clients.
  22.  
  23.        An extensive description of the services that  the  server
  24.        can provide is given in the man page for the configuration
  25.        file controlling the attributes  of  those  services  (see
  26.        ssmmbb..ccoonnff((55))))..  TThhiiss  mmaann  ppaaggee  wwiillll nnoott ddeessccrriibbee tthhee sseerr--
  27.        vviicceess,, bbuutt will concentrate on the administrative  aspects
  28.        of running the server.
  29.  
  30.        Please  note  that there are significant security implica-
  31.        tions to running this server, and  ssmmbb..ccoonnff((55))  sshhoouulldd  bbee
  32.        rreeggaarrddeedd  aass  mmaannddaattoorryy  rreeaaddiinngg  bbeeffoorree  pprroocceeeeddiinngg  wwiitthh
  33.        installation.
  34.  
  35.        A session is created whenever a client requests one.  Each
  36.        client  gets  a  copy of the server for each session. This
  37.        copy then services all connections made by the client dur-
  38.        ing that session. When all connections from its client are
  39.        are closed, the copy of the server for that client  termi-
  40.        nates.
  41.  
  42.        The  configuration  file  is  automatically reloaded if it
  43.        changes. You can force a reload by sending a SIGHUP to the
  44.        server.
  45.  
  46.  
  47. OOPPTTIIOONNSS
  48.        --DD
  49.  
  50.           If specified, this parameter causes the server to oper-
  51.           ate as a daemon. That is, it detaches itself  and  runs
  52.           in the background, fielding requests on the appropriate
  53.           port.
  54.  
  55.           By default, the server will NOT operate as a daemon.
  56.  
  57.        --aa
  58.  
  59.           If this parameter is specified, the log files  will  be
  60.           overwritten  with  each new connection. By default, the
  61.  
  62.  
  63.  
  64. smbd                        17/1/1995                           1
  65.  
  66.  
  67.  
  68.  
  69.  
  70. SMBD(8)                        smbd                       SMBD(8)
  71.  
  72.  
  73.           log files will be appended to.
  74.  
  75.        --dd _d_e_b_u_g_l_e_v_e_l
  76.  
  77.           debuglevel is an integer from 0 to 5.
  78.  
  79.           The default value if this parameter is not specified is
  80.           zero.
  81.  
  82.           The  higher  this value, the more detail will be logged
  83.           to the log files about the activities of the server. At
  84.           level 0, only critical errors and serious warnings will
  85.           be logged. Level 1 is a reasonable level for day to day
  86.           running  -  it  generates a small amount of information
  87.           about operations carried out.
  88.  
  89.           Levels above 1 will generate  considerable  amounts  of
  90.           log  data, and should only be used when investigating a
  91.           problem. Levels above 3 are designed for  use  only  by
  92.           developers  and generate HUGE amounts of log data, most
  93.           of which is extremely cryptic.
  94.  
  95.        --ll _l_o_g _f_i_l_e
  96.  
  97.           If specified, _l_o_g_f_i_l_e specifies a  base  filename  into
  98.           which  operational data from the running server will be
  99.           logged.
  100.  
  101.           The default base name is specified at compile time.
  102.  
  103.           The base name is  used  to  generate  actual  log  file
  104.           names.  For  example,  if the name specified was "log",
  105.           the following files would be used for log data:
  106.  
  107.              log.debug (containing debugging information)
  108.  
  109.              log.in (containing inbound transaction data)
  110.  
  111.              log.out (containing outbound transaction data)
  112.  
  113.           The log  files  generated  are  never  removed  by  the
  114.           server.
  115.  
  116.        --OO _s_o_c_k_e_t _o_p_t_i_o_n_s
  117.  
  118.           See  the  socket  options  section  of  smb.conf(5) for
  119.           details
  120.  
  121.        --pp _p_o_r_t _n_u_m_b_e_r
  122.  
  123.           port number is a positive integer value.
  124.  
  125.           The default value if this parameter is not specified is
  126.           139.
  127.  
  128.  
  129.  
  130. smbd                        17/1/1995                           2
  131.  
  132.  
  133.  
  134.  
  135.  
  136. SMBD(8)                        smbd                       SMBD(8)
  137.  
  138.  
  139.           This  number  is the port number that will be used when
  140.           making connections to the server from client  software.
  141.           The standard (well-known) port number for the server is
  142.           139, hence the default. If you wish to run  the  server
  143.           as  an  ordinary user rather than as root, most systems
  144.           will require you to use a port number greater than 1024
  145.           -  ask your system administrator for help if you are in
  146.           this situation.
  147.  
  148.           This parameter is not normally specified except in  the
  149.           above situation.
  150.  
  151.        --ss _c_o_n_f_i_g_u_r_a_t_i_o_n _f_i_l_e
  152.  
  153.           The  default  configuration  file name is determined at
  154.           compile time.
  155.  
  156.           The file specified contains the  configuration  details
  157.           required  by  the server.  The information in this file
  158.           includes  server-specific  information  such  as   what
  159.           printcap  file  to  use, as well as descriptions of all
  160.           the  services  that  the  server  is  to  provide.  See
  161.           ssmmbb..ccoonnff((55)) ffoorr mmoorree iinnffoorrmmaattiioonn..
  162.  
  163.  
  164. FFIILLEESS
  165.        //eettcc//iinneettdd..ccoonnff
  166.  
  167.           If  the  server  is to be run by the inetd meta-daemon,
  168.           this file must contain suitable startup information for
  169.           the  meta-daemon. See the section "INSTALLATION" below.
  170.  
  171.        //eettcc//rrcc
  172.  
  173.           (or whatever initialisation script your system uses)
  174.  
  175.           If running the server as a daemon at startup, this file
  176.           will  need  to  contain an appropriate startup sequence
  177.           for the server. See the section "INSTALLATION" below.
  178.  
  179.        //eettcc//sseerrvviicceess
  180.  
  181.           If running the server via the meta-daemon  inetd,  this
  182.           file  must contain a mapping of service name (eg., net-
  183.           bios-ssn)  to service port (eg., 139) and protocol type
  184.           (eg., tcp). See the section "INSTALLATION" below.
  185.  
  186.        //uussrr//llooccaall//ssmmbb//ssmmbb..ccoonnff
  187.  
  188.           This  file  describes all the services the server is to
  189.           make available to clients.  See  ssmmbb..ccoonnff((55))  ffoorr  mmoorree
  190.           iinnffoorrmmaattiioonn..
  191.  
  192.  
  193.  
  194.  
  195.  
  196. smbd                        17/1/1995                           3
  197.  
  198.  
  199.  
  200.  
  201.  
  202. SMBD(8)                        smbd                       SMBD(8)
  203.  
  204.  
  205. LLIIMMIITTAATTIIOONNSS
  206.        On  some systems smbd cannot change uid back to root after
  207.        a setuid() call.  Such systems are called  "trapdoor"  uid
  208.        systems.  If you have such a system, you will be unable to
  209.        connect from a client (such as  a  PC)  as  two  different
  210.        users  at  once.  Attempts to connect the second user will
  211.        result in "access denied" or similar.
  212.  
  213.  
  214. EENNVVIIRROONNMMEENNTT VVAARRIIAABBLLEESS
  215.        PPRRIINNTTEERR
  216.  
  217.           If no printer name is specified to printable  services,
  218.           most  systems  will  use the value of this variable (or
  219.           "lp" if this variable is not defined) as  the  name  of
  220.           the printer to use. This is not specific to the server,
  221.           however.
  222.  
  223.  
  224. IINNSSTTAALLLLAATTIIOONN
  225.        The location of the server and its support files is a mat-
  226.        ter  for  individual  system administrators. The following
  227.        are thus suggestions only.
  228.  
  229.        It is recommended that the server  software  be  installed
  230.        under the /usr/local hierarchy, in a directory readable by
  231.        all, writeable only by root.  The  server  program  itself
  232.        should  be executable by all, as users may wish to run the
  233.        server themselves (in which case it  will  of  course  run
  234.        with  their privileges).  The server should NOT be setuid.
  235.        On some systems it may be worthwhile to make  smbd  setgid
  236.        to an empty group. This is because some systems may have a
  237.        security hole where daemon processes that  become  a  user
  238.        can  be  attached to with a debugger. Making the smbd file
  239.        setgid to an empty group may prevent this hole from  being
  240.        exploited.  This  secrity  hole  and the suggested fix has
  241.        only been confirmed on Linux at the time this was written.
  242.        It  is  possible  that  this hole only exists in Linux, as
  243.        testing on other systems has thus far  shown  them  to  be
  244.        immune.
  245.  
  246.        The server log files should be put in a directory readable
  247.        and writable only by root, as the log  files  may  contain
  248.        sensitive information.
  249.  
  250.        The  configuration  file  should  be placed in a directory
  251.        readable and writable only by root, as  the  configuration
  252.        file  controls  security  for  the services offered by the
  253.        server. The configuration file can be made readable by all
  254.        if  desired,  but this is not necessary for correct opera-
  255.        tion of the server and is not recommended. A  sample  con-
  256.        figuration  file  "smb.conf.sample"  is  supplied with the
  257.        source to the server - this may be renamed  to  "smb.conf"
  258.        and modified to suit your needs.
  259.  
  260.  
  261.  
  262. smbd                        17/1/1995                           4
  263.  
  264.  
  265.  
  266.  
  267.  
  268. SMBD(8)                        smbd                       SMBD(8)
  269.  
  270.  
  271.        The remaining notes will assume the following:
  272.  
  273.           smbd (the server program) installed in /usr/local/smb
  274.  
  275.           smb.conf   (the   configuration   file)   installed  in
  276.           /usr/local/smb
  277.  
  278.           log files stored in /var/adm/smblogs
  279.  
  280.        The server may be run either as a daemon by  users  or  at
  281.        startup, or it may be run from a meta-daemon such as inetd
  282.        upon request. If run as a daemon, the server  will  always
  283.        be ready, so starting sessions will be faster. If run from
  284.        a meta-daemon some memory will be saved and utilities such
  285.        as the tcpd TCP-wrapper may be used for extra security.
  286.  
  287.        When  you've  decided,  continue  with either "RUNNING THE
  288.        SERVER AS A DAEMON" or "RUNNING THE SERVER ON REQUEST".
  289.  
  290. RRUUNNNNIINNGG TTHHEE SSEERRVVEERR AASS AA DDAAEEMMOONN
  291.        To run the server as a daemon from the command line,  sim-
  292.        ply  put  the "-D" option on the command line. There is no
  293.        need to place an ampersand at the end of the command  line
  294.        -  the "-D" option causes the server to detach itself from
  295.        the tty anyway.
  296.  
  297.        Any user can run the server as a daemon  (execute  permis-
  298.        sions  permitting,  of course). This is useful for testing
  299.        purposes, and may even be useful as a temporary substitute
  300.        for  something  like  ftp. When run this way, however, the
  301.        server will only have the privileges of the user  who  ran
  302.        it.
  303.  
  304.        To  ensure that the server is run as a daemon whenever the
  305.        machine is started, and to ensure that it runs as root  so
  306.        that  it can serve multiple clients, you will need to mod-
  307.        ify the system startup files.  Wherever  appropriate  (for
  308.        example,  in  /etc/rc), insert the following line, substi-
  309.        tuting port number, log file location, configuration  file
  310.        location and debug level as desired:
  311.  
  312.           /usr/local/smb/smbd   -D   -l  /var/adm/smblogs/log  -s
  313.           /usr/local/smb/smb.conf
  314.  
  315.        (The above should appear in your initialisation script  as
  316.        a  single  line.   Depending on your terminal characteris-
  317.        tics, it may not appear that way in this man page. If  the
  318.        above appears as more than one line, please treat any new-
  319.        lines or indentation as a single space or TAB  character.)
  320.  
  321.        If  the  options  used at compile time are appropriate for
  322.        your system, all parameters except the desired debug level
  323.        and  "-D" may be omitted. See the section "OPTIONS" above.
  324.  
  325.  
  326.  
  327.  
  328. smbd                        17/1/1995                           5
  329.  
  330.  
  331.  
  332.  
  333.  
  334. SMBD(8)                        smbd                       SMBD(8)
  335.  
  336.  
  337. RRUUNNNNIINNGG TTHHEE SSEERRVVEERR OONN RREEQQUUEESSTT
  338.        If your system uses a meta-daemon such as inetd,  you  can
  339.        arrange to have the smbd server started whenever a process
  340.        attempts to connect to it. This requires  several  changes
  341.        to  the  startup  files  on  the  host machine. If you are
  342.        experimenting as an ordinary user rather than as root, you
  343.        will  need  the assistance of your system administrator to
  344.        modify the system files.
  345.  
  346.        You will probably want to set up the name server  nnmmbbdd  at
  347.        the same time as the smbd - refer to the man page nnmmbbdd((88))..
  348.  
  349.        First, ensure that  a  port  is  configured  in  the  file
  350.        /etc/services.  The  well-known port 139 should be used if
  351.        possible, though any port may be used.
  352.  
  353.        Ensure  that  a  line  similar  to  the  following  is  in
  354.        /etc/services:
  355.  
  356.           netbios-ssn    139/tcp
  357.  
  358.        Note  for  NIS/YP  users - you may need to rebuild the NIS
  359.        service maps rather than alter  your  local  /etc/services
  360.        file.
  361.  
  362.        Next,  put a suitable line in the file /etc/inetd.conf (in
  363.        the unlikely event that you are using a meta-daemon  other
  364.        than inetd, you are on your own). Note that the first item
  365.        in this line matches the service  name  in  /etc/services.
  366.        Substitute appropriate values for your system in this line
  367.        (see iinneettdd((88))))::
  368.  
  369.           netbios-ssn stream tcp nowait root  /usr/local/smb/smbd
  370.           -d1 -l/var/adm/smblogs/log -s/usr/local/smb/smb.conf
  371.  
  372.        (The  above  should  appear in /etc/inetd.conf as a single
  373.        line. Depending on your terminal characteristics,  it  may
  374.        not  appear  that  way  in  this  man  page.  If the above
  375.        appears as more than one line, please treat  any  newlines
  376.        or indentation as a single space or TAB character.)
  377.  
  378.        Note  that there is no need to specify a port number here,
  379.        even if you are using a non-standard port number.
  380.  
  381.        Lastly, edit the configuration file  to  provide  suitable
  382.        services. To start with, the following two services should
  383.        be all you need:
  384.  
  385.           [homes]
  386.               writable = yes
  387.  
  388.           [printers]
  389.               writable = no
  390.               printable = yes
  391.  
  392.  
  393.  
  394. smbd                        17/1/1995                           6
  395.  
  396.  
  397.  
  398.  
  399.  
  400. SMBD(8)                        smbd                       SMBD(8)
  401.  
  402.  
  403.               path = /tmp
  404.               public = yes
  405.  
  406.        This will allow you to connect to your home directory  and
  407.        print  to  any  printer supported by the host (user privi-
  408.        leges permitting).
  409.  
  410. TTEESSTTIINNGG TTHHEE IINNSSTTAALLLLAATTIIOONN
  411.        If running the server as a daemon, execute it before  pro-
  412.        ceeding. If using a meta-daemon, either restart the system
  413.        or kill and restart  the  meta-daemon.  Some  versions  of
  414.        inetd  will  reread  their  configuration  tables  if they
  415.        receive a HUP signal.
  416.  
  417.        If your machine's name is "fred" and your name is  "mary",
  418.        you   should  now  be  able  to  connect  to  the  service
  419.        "\\fred\mary".
  420.  
  421.        To properly test and experiment with the server, we recom-
  422.        mend using the smbclient program (see ssmmbbcclliieenntt((11))))..
  423.  
  424. VVEERRSSIIOONN
  425.        This  man  page  is (mostly) correct for version 1.9.00 of
  426.        the Samba suite, plus some of the recent  patches  to  it.
  427.        These notes will necessarily lag behind development of the
  428.        software, so it is  possible  that  your  version  of  the
  429.        server  has  extensions or parameter semantics that differ
  430.        from or are not covered by this man  page.  Please  notify
  431.        these to the address below for rectification.
  432.  
  433. SSEEEE AALLSSOO
  434.        hhoossttss__aacccceessss((55)),,   iinneettdd((88)),,  nnmmbbdd((88)),,  ssmmbb..ccoonnff((55)),,  ssmmbb--
  435.        cclliieenntt((11)),, tteessttppaarrmm((11)),, tteessttpprrnnss((11))
  436.  
  437.  
  438. DDIIAAGGNNOOSSTTIICCSS
  439.        [This section under construction]
  440.  
  441.        Most diagnostics issued by the  server  are  logged  in  a
  442.        specified log file. The log file name is specified at com-
  443.        pile time, but may be overridden on the command line.
  444.  
  445.        The number and nature of diagnostics available depends  on
  446.        the  debug level used by the server. If you have problems,
  447.        set the debug level to 3 and peruse the log files.
  448.  
  449.        Most messages are  reasonably  self-explanatory.  Unfortu-
  450.        nately,  at  time  of creation of this man page the source
  451.        code is still too fluid to  warrant  describing  each  and
  452.        every  diagnostic. At this stage your best bet is still to
  453.        grep the source code and inspect the conditions that  gave
  454.        rise to the diagnostics you are seeing.
  455.  
  456.  
  457.  
  458.  
  459.  
  460. smbd                        17/1/1995                           7
  461.  
  462.  
  463.  
  464.  
  465.  
  466. SMBD(8)                        smbd                       SMBD(8)
  467.  
  468.  
  469. BBUUGGSS
  470.        None known.
  471.  
  472. CCRREEDDIITTSS
  473.        The  original  Samba  software  and related utilities were
  474.        created by Andrew Tridgell (samba-bugs@anu.edu.au). Andrew
  475.        is also the Keeper of the Source for this project.
  476.  
  477.        This man page written by Karl Auer (Karl.Auer@anu.edu.au)
  478.  
  479.        See  ssmmbb..ccoonnff((55))  ffoorr  aa  ffuullll  lliisstt  ooff  ccoonnttrriibbuuttoorrss aanndd
  480.        ddeettaaiillss oonn hhooww ttoo submit bug reports, comments etc.
  481.  
  482.  
  483.  
  484.  
  485.  
  486.  
  487.  
  488.  
  489.  
  490.  
  491.  
  492.  
  493.  
  494.  
  495.  
  496.  
  497.  
  498.  
  499.  
  500.  
  501.  
  502.  
  503.  
  504.  
  505.  
  506.  
  507.  
  508.  
  509.  
  510.  
  511.  
  512.  
  513.  
  514.  
  515.  
  516.  
  517.  
  518.  
  519.  
  520.  
  521.  
  522.  
  523.  
  524.  
  525.  
  526. smbd                        17/1/1995                           8
  527.  
  528.  
  529.